/***************************************************
Class: ProjObject
Includes: stdafx.h, Mesh.h, WorldObject.h
Editors: Gindi
Existing Issues: None
Description: Class for the projectile objects such as bullets that 
exist in the application.
***************************************************/
#pragma once

#include "stdafx.h"
#include "Mesh.h"
#include "WorldObject.h"

class ProjObject {
public:
	ProjObject() {}
	ProjObject(string mFile) { modelFile = mFile; }
	~ProjObject() { Release(); }
	void Release();
	bool Initialize(LPDIRECT3DDEVICE9 pDevice);
	bool InitializeMesh(LPDIRECT3DDEVICE9 pDevice);
	void InitializePhysicsInfo();
	void Update(float elapsedTime);
	void UpdateMovement(float elapsedTime);
	void Render(LPDIRECT3DDEVICE9 pDevice);

public:
	Mesh			mesh;
	MeshInstance	meshInst;
	bool			deleteNextUpdate;
	float			damage;
	float			distToCam;
	float			yVelocity;
	float			range;
	D3DXVECTOR3		initialPosition;
	string			alignment;
	string			modelFile;
	string			name;
	string			type;
	PhysicsInfo		physicsInfo;
	WorldObject*	sourceUnit;
};